package com.zpphis.service.impl;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.zpphis.entity.Drugs;
import com.zpphis.mapper.DrugsMapper;
import com.zpphis.service.IDrugsService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Map;

/**
 * <p>
 * 服务实现类
 * </p>
 *
 * @author zpp
 * @since 2022-11-22
 */
@Service
public class DrugsServiceImpl extends ServiceImpl<DrugsMapper, Drugs> implements IDrugsService {

    @Autowired
    private DrugsMapper drugsMapper;

    @Override
    public Page<Map<String, Object>> pageExtend(Page<Map<String, Object>> p, String queryString) {
        queryString = "%" + queryString + "%";
        return drugsMapper.selectMapsPage(p, queryString);
    }
}
